<template>
	<view>
		<view>
			<dsl-navbar title="简历" isBack bgTopImg="white"></dsl-navbar>
			<view v-if="resumeData.name">

				<view class="bg-white">
					<view class="flex padding align-center ">
						<view class="">
							<image :src="resumeData.image" mode="aspectFill" class="user_image round bg-grey"></image>
						</view>
						<view class="margin-left ">
							<view class="flex align-center">
								<view class="user_name">{{resumeData.name}}</view>
								<image
									:src="resumeData.gender==1?'/static/icon/nan.png' :'/static/icon/icon_xingbienv.png'"
									mode="widthFix" style="width: 24rpx;" class="margin-left"></image>
								<view class="user_table margin-left">{{resumeData.degree}}</view>
							</view>
							<view class="text-xs align-center margin-top-sm">
								<view>出生日期：{{resumeData.birthdaytime}}</view>
								<view class="margin-left">工作经验：{{resumeData.experience}}</view>
							</view>
						</view>
					</view>
					<view class="rowsb padding">
						<view>意向城市：{{resumeData.address}}</view>
						<view>意向岗位：{{resumeData.recruitclassify_name}}</view>
					</view>
					<view class="rowsb padding-lr">
						<view>
							目前状态：{{resumeData.status==1?'离职-随时到岗':resumeData.status==2?'在职':resumeData.status==3?'在职-考虑机会':resumeData.status==4?'在职-暂不考虑':'暂无状态'}}
						</view>
					</view>
					<view class="rowsb padding">
						<view>期望薪资:{{resumeData.money}}</view>
					</view>

				</view>
				<view class="bg-white padding margin-top-sm">
					<view class="text-lg text-bold">个人优势</view>
					<view class="margin-top">
						{{resumeData.superiority}}
					</view>
				</view>
				<view class="bg-white padding margin-top-xs">
					<view class="text-lg text-bold">联系方式</view>
					<view class="margin-top">
						手机号： {{resumeData.tel}}
					</view>
				</view>
				<view class="bg-white padding margin-top-xs">
					<view class="text-lg text-bold">工作经历</view>
					<view class="margin-top">
						<view>公司名称：{{resumeData.resume_work.work}}</view>
						<view class="margin-top-sm">担任职位：{{resumeData.resume_work.name}}</view>
						<view class="margin-top-sm">工作内容：{{resumeData.resume_work.job}}</view>
					</view>
				</view>

				<view class="bg-white padding margin-top-xs">
					<view class="text-lg text-bold">教育经历</view>
					<view class="margin-top">
						<view>学历：{{resumeData.resume_school.name}}</view>
						<view>专业：{{resumeData.resume_school.major}}</view>
						<view>学校：{{resumeData.resume_school.school}}</view>
					</view>
				</view>
				<view class="bg-white padding margin-top-xs">
					<view class="text-lg text-bold">证书</view>
					<view class="flex flex-wrap">
						<view class="margin-top rowsc" v-for="(i,index) in 1" style="width: 25%;">
							<image :src="resumeData.images" mode="aspectFill" class="bg-grey"
								style="width: 142rpx;height: 142rpx;"></image>
						</view>
					</view>
				</view>
			</view>
			<view v-else class="text-center text-sm padding">
				暂无简历
			</view>
		</view>
	</view>
</template>

<script>
	import {
		getresume
	} from '@/common/path.js'
	export default {
		data() {
			return {
				userId: '', //用户id
				resumeData: {}, //简历详情
			}
		},
		//生命周期函数
		onReady() {},
		onLoad(option) {
			this.userId = option.id
			this.getresume()
		},
		onShow() {},
		methods: {
			//简历详情
			getresume() {
				let data = {
					user_id: this.userId
				}
				this.Http.POST(getresume, data)
					.then((res) => {
						console.log('[简历详情]', res);
						if (res.code == 1) {
							this.resumeData = res.data
						} else {
							this.resumeData = {}
						}
					})
			}
		},
		computed: {},
		components: {}
	}
</script>

<style>
	.user_image {
		height: 119rpx;
		width: 119rpx;
	}

	.user_name {
		font-size: 38rpx;
		font-family: PingFang SC;
		font-weight: bold;
		color: #333333;
		opacity: 1;
	}

	.user_table {
		width: 72rpx;
		height: 30rpx;
		border: 1rpx solid #2B9AFF;
		border-radius: 20rpx;
		color: #2B9AFF;
		font-size: 20rpx;
		line-height: 30rpx;
		text-align: center;
	}

	page {
		background-color: #F7F6FA;
	}
</style>
